<?php

/*
|--------------------------------------------------------------------------
| Routes File
|--------------------------------------------------------------------------
|
| Here is where you will register all of the routes in an application.
| It's a breeze. Simply tell Laravel the URIs it should respond to
| and give it the controller to call when that URI is requested.
|
*/




/*
|--------------------------------------------------------------------------
| Application Routes
|--------------------------------------------------------------------------
|
| This route group applies the "web" middleware group to every route
| it contains. The "web" middleware group is defined in your HTTP
| kernel and includes session state, CSRF protection, and more.
|
*/

Route::group(['middleware' => ['web']], function () {
    Route::get('/', 'Comments\CommentController@content');
//regist
    Route::get('message/regist', function(){
        return view('messages/regist');
    });
    Route::post('message/regist', 'CommentController@regist');

//login
    Route::get('message/login', function(){
        return view('messages/login');
    });
    Route::post('message/login', 'CommentController@login');

//quit
    Route::get('message/quit', 'CommentController@quit');


//content
    Route::get('message/content', 'CommentController@content');
    Route::post('message/content', 'CommentController@content');

//manage
    Route::get('message/manage', 'CommentController@manage');

//handle_member
    Route::get('message/handle_member', 'CommentController@handle_member');
//handle_admin
    Route::get('message/handle_admin', 'CommentController@handle_admin');


    Route::get('/error',function(){
       abort(404);
    });
});
